<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>


<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script src="http://cdn.bootcss.com/jquery/1.11.3/jquery.min.js"></script>
<link rel="stylesheet" href="${home}/css/reset.css" />
<link rel="stylesheet" href="${home}/css/style.css" />
<title>Insert title here</title>
<script type="text/javascript">
 function save(){	
	 $ajax.({
		 type : "POST",
		 url : "${home}/leave/updLeaveEntity",
		 data : {"name":$("#name").val(),"phone":$("#phone").val,"content":("#content").val},
		 dataType : "json",
		 success : function(data){
			 promptBox.hide();
			 if(data.status == 100){
				 alert("添加成功");
				 window.location.reload();				 
			 }else{
				 alert("添加失败");
			 }
		 }
		 
	 });
 }
</script>
<body>

<div>
	<input id="newAuthor" name="author" type="text" value="${sessionScope.USERKEY.userName}" maxlength="8">
</div>

	
   留言人: <input type="text" id="name" name ="name" /><br/>
  联系方式: <input class="easyui-validatebox" id="phone" type="text" name ="phone" /><br/>
	<label>留言内容</label>	
		<textarea  class="txt" rows="10" cols="100" id="content" name="centent">
	
		</textarea>
	
		<input class="button" type="button" onclick="save()" value="提交"/>
	
	

</div>

   
</body>

</html>